package com.atguigu.gmall.seckill.service;

import com.atguigu.gmall.common.result.ResultCodeEnum;
import com.atguigu.gmall.order.entity.OrderInfo;
import com.atguigu.gmall.order.vo.OrderSubmitVo;
import com.atguigu.gmall.seckill.entity.SeckillGoods;

import java.util.List;

/**
 * @Description
 * @Return
 * @Author https://weiranyi.github.io
 * @Date Created in 2022-12-26 10:48
 **/
public interface SeckillBizService {
    // 上架
    void upSeckillGoods(String date);
    // 获取今天上架的商品【主要用到自己的本地缓存】
    List<SeckillGoods> getTodaySeckillGoods(String date);

    SeckillGoods getSeckillGoodsDetails(Long skuId);

    String generateSeckillCode(Long skuId);

    void seckillOrder(String skuId, String skuIdStr);

    ResultCodeEnum checkOrder(Long skuId, String userId);

    OrderInfo getSeckillOrderInfo(Long skuId, String userId);

    Long submitOrder(OrderSubmitVo vo);
}
